/* global Vue */

// var apiURL = 'https://api.github.com/repos/vuejs/vue/commits?per_page=3&sha='

/**
 * Actual demo
 */

new Vue({

  el: '#demo',

  data() {
    return {
      test: { age: 10, name: 'hua' },
      name: 'xxx'
    }
  },
  watch: {
    "test": {
      hanlder: function (newVal, oldVal) {
        console.log(newVal, oldVal)
      },
      deep: true
    }
  },
  mounted() {
    console.log('mounted');
    setTimeout(() => {
      this.test.xxx = 'xxx';
      this.name = 'yyyy';
    },1000);
  },
})
